function T = dynamic_g2_tt(T, y, x, params, steady_state, it_)
% function T = dynamic_g2_tt(T, y, x, params, steady_state, it_)
%
% File created by Dynare Preprocessor from .mod file
%
% Inputs:
%   T             [#temp variables by 1]     double  vector of temporary terms to be filled by function
%   y             [#dynamic variables by 1]  double  vector of endogenous variables in the order stored
%                                                    in M_.lead_lag_incidence; see the Manual
%   x             [nperiods by M_.exo_nbr]   double  matrix of exogenous variables (in declaration order)
%                                                    for all simulation periods
%   steady_state  [M_.endo_nbr by 1]         double  vector of steady state values
%   params        [M_.param_nbr by 1]        double  vector of parameter values in declaration order
%   it_           scalar                     double  time period for exogenous variables for which
%                                                    to evaluate the model
%
% Output:
%   T           [#temp variables by 1]       double  vector of temporary terms
%

assert(length(T) >= 185);

T = bbeffectivedemandmatchirf_order4.dynamic_g1_tt(T, y, x, params, steady_state, it_);

T(85) = getPowerDeriv(y(30)*y(4),params(1),2);
T(86) = getPowerDeriv(y(36)*y(21),1-params(1),2);
T(87) = (1-y(21))*(1-y(21))*(1-y(21))*(1-y(21));
T(88) = getPowerDeriv(y(10)*T(4)*T(5),T(6),2);
T(89) = params(24)*T(13)*T(13)*T(88);
T(90) = getPowerDeriv(T(8),T(9),2);
T(91) = params(24)*(T(40)*T(5)*T(52)+T(13)*T(5)*y(10)*T(52)*T(88));
T(92) = y(10)*T(4)*T(74)*T(88);
T(93) = params(24)*(T(40)*T(4)*T(74)+T(13)*T(92));
T(94) = params(24)*T(40)*y(10)*T(4)*T(74)*T(90);
T(95) = getPowerDeriv(y(11),params(6),2);
T(96) = params(24)*(T(5)*y(10)*T(52)*T(5)*y(10)*T(52)*T(88)+T(40)*T(5)*y(10)*T(95));
T(97) = params(24)*(T(5)*y(10)*T(52)*T(92)+T(40)*y(10)*T(52)*T(74));
T(98) = params(2)*getPowerDeriv(y(17),T(7),2);
T(99) = getPowerDeriv(1-y(21),1-params(6),2);
T(100) = params(24)*(y(10)*T(4)*T(74)*T(92)+T(40)*y(10)*T(4)*T(99));
T(101) = (-((-((-((y(35)+params(15))*params(1)))*(y(20)+y(20))))/(y(20)*y(20)*y(20)*y(20))));
T(102) = (-1)/(y(4)*y(4));
T(103) = (-((-y(18))*(y(4)+y(4))))/(y(4)*y(4)*y(4)*y(4));
T(104) = (-((-y(10))*(y(1)+y(1))))/(y(1)*y(1)*y(1)*y(1));
T(105) = T(13)*T(104);
T(106) = T(105)/T(17);
T(107) = getPowerDeriv(T(18),T(6),2);
T(108) = (-1)/(y(1)*y(1));
T(109) = T(13)*T(108);
T(110) = T(109)/T(17);
T(111) = T(45)*T(107);
T(112) = (-(T(37)*T(47)))/T(48);
T(113) = T(49)*T(107);
T(114) = params(2)*T(38)*T(39)*T(50)+T(20)*params(2)*(T(39)*T(112)+T(38)*T(113));
T(115) = T(36)*T(5)*T(52)/T(17);
T(116) = T(54)*T(107);
T(117) = params(2)*T(38)*T(39)*T(55)+T(20)*params(2)*(T(39)*T(115)+T(38)*T(116));
T(118) = (-(T(37)*T(71)))/T(48);
T(119) = T(72)*T(107);
T(120) = T(36)*T(4)*T(74)/T(17);
T(121) = T(75)*T(107);
T(122) = (-(T(44)*T(47)))/T(48);
T(123) = params(2)*T(39)*T(45)*T(50)+T(20)*params(2)*(T(45)*T(113)+T(39)*T(122));
T(124) = T(43)*T(5)*T(52)/T(17);
T(125) = params(2)*T(39)*T(45)*T(55)+T(20)*params(2)*(T(45)*T(116)+T(39)*T(124));
T(126) = (-(T(44)*T(71)))/T(48);
T(127) = T(43)*T(4)*T(74)/T(17);
T(128) = getPowerDeriv(y(2),params(6),2);
T(129) = T(16)*T(128);
T(130) = T(17)*T(47)+T(17)*T(47);
T(131) = T(48)*T(48);
T(132) = (T(48)*(-(T(14)*T(129)))-(-(T(14)*T(47)))*T(130))/T(131);
T(133) = params(2)*T(39)*T(49)*T(50)+params(2)*T(39)*T(49)*T(50)+T(20)*params(2)*(T(49)*T(113)+T(39)*T(132));
T(134) = (-(T(47)*T(12)*T(5)*T(52)))/T(48);
T(135) = params(2)*(T(49)*T(116)+T(39)*T(134));
T(136) = (-1)/(y(11)*y(11));
T(137) = params(2)*T(39)*T(49)*T(55)+T(20)*T(135)+T(50)*params(2)*T(39)*T(54)+T(19)*T(136);
T(138) = T(17)*T(71)+T(17)*T(71);
T(139) = (T(48)*(-(T(14)*T(46)*T(70)))-(-(T(14)*T(47)))*T(138))/T(131);
T(140) = T(20)*params(2)*(T(49)*T(119)+T(39)*T(139))+T(50)*params(2)*T(39)*T(72);
T(141) = (-(T(47)*T(12)*T(4)*T(74)))/T(48);
T(142) = params(2)*(T(49)*T(121)+T(39)*T(141));
T(143) = T(12)*T(5)*T(95)/T(17);
T(144) = params(2)*(T(54)*T(116)+T(39)*T(143));
T(145) = (-((-y(2))*(y(11)+y(11))))/(y(11)*y(11)*y(11)*y(11));
T(146) = params(2)*T(39)*T(54)*T(55)+T(20)*T(144)+params(2)*T(39)*T(54)*T(55)+T(19)*T(145);
T(147) = (-(T(12)*T(5)*T(52)*T(71)))/T(48);
T(148) = params(2)*(T(54)*T(119)+T(39)*T(147));
T(149) = T(12)*T(52)*T(74)/T(17);
T(150) = params(2)*(T(54)*T(121)+T(39)*T(149));
T(151) = (-((-T(21))*(y(3)+y(3))))/(y(3)*y(3)*y(3)*y(3));
T(152) = getPowerDeriv(T(22),1-T(7),2);
T(153) = T(59)*T(151)+T(58)*T(58)*T(152);
T(154) = (-T(78))/(y(3)*y(3));
T(155) = T(59)*T(154)+T(58)*T(79)*T(152);
T(156) = getPowerDeriv(1-y(5),1-params(6),2);
T(157) = T(15)*T(156);
T(158) = (T(48)*(-(T(14)*T(157)))-(-(T(14)*T(71)))*T(138))/T(131);
T(159) = (-(T(71)*T(12)*T(4)*T(74)))/T(48);
T(160) = params(2)*(T(72)*T(121)+T(39)*T(159));
T(161) = T(12)*T(4)*T(99)/T(17);
T(162) = params(2)*(T(75)*T(121)+T(39)*T(161));
T(163) = getPowerDeriv(y(32),1-params(9),2);
T(164) = T(163)/y(3);
T(165) = T(79)*T(79)*T(152)+T(59)*T(164);
T(166) = getPowerDeriv(y(41),(-1),2);
T(167) = (-((-y(35))*(y(8)+y(8))))/(y(8)*y(8)*y(8)*y(8));
T(168) = T(26)*T(167)-T(81)*T(81);
T(169) = (-1)/(y(8)*y(8));
T(170) = (-1)/(y(19)*y(19));
T(171) = T(64)*params(8)*T(68)+params(8)*(T(28)-params(3))*T(170)+params(8)*T(64)*T(68)+T(28)*params(8)*T(170)-T(10)*(2*(T(28)-params(3))*T(170)+T(64)*2*T(68));
T(172) = y(42)*T(171);
T(173) = y(44)*T(172);
T(174) = (-(y(44)*y(42)*T(65)));
T(175) = (-((-y(39))*(y(19)+y(19))))/(y(19)*y(19)*y(19)*y(19));
T(176) = T(68)*params(8)*T(68)+params(8)*(T(28)-params(3))*T(175)+T(68)*params(8)*T(68)+T(28)*params(8)*T(175)-T(10)*(T(68)*2*T(68)+2*(T(28)-params(3))*T(175));
T(177) = y(42)*T(176);
T(178) = y(44)*T(177);
T(179) = (-(y(44)*y(42)*T(69)));
T(180) = y(25)*y(25)*y(25)*y(25);
T(181) = (-((-y(47))*(y(35)+y(35))))/(y(35)*y(35)*y(35)*y(35));
T(182) = y(44)*params(7)*(T(31)-1)*T(181);
T(183) = (-1)/(y(35)*y(35));
T(184) = (-((-1)/(y(22)*y(22))));
T(185) = T(35)*T(35)*(-(2*T(34)))-(-(T(34)*2*y(22)))*(T(35)*2*y(22)+T(35)*2*y(22));

end
